package com.sqx.modules.health.service.impl;

import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.sqx.modules.health.entity.NcgDeviceWatch;
import com.sqx.modules.health.mapper.NcgDeviceWatchMapper;
import com.sqx.modules.health.service.INcgDeviceWatchService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 * 智能手表设备表 服务实现类
 * </p>
 *
 * @author xglhappy
 * @since 2022-04-21
 */
@Service
public class NcgDeviceWatchServiceImpl extends ServiceImpl<NcgDeviceWatchMapper, NcgDeviceWatch> implements INcgDeviceWatchService {

    @Autowired
    private NcgDeviceWatchMapper deviceWatchMapper;

    @Override
    public List<NcgDeviceWatch> getAllHospitalDevice(Long hid) {
        return deviceWatchMapper.getAllHospitalDevice(hid);
    }

    @Override
    public List<JSONObject> getDeviceImei(Integer type, Long hid) {
        return deviceWatchMapper.getDeviceImei(type, hid);
    }

    @Override
    public List<NcgDeviceWatch> getDeviceHid(Long hid) {
        return deviceWatchMapper.getDeviceHid(hid);
    }

    @Override
    public void editBinding(Object uid, Object doctorid, Object imei) {
        deviceWatchMapper.editBinding(uid, doctorid, imei);
    }

    @Override
    public NcgDeviceWatch getDeviceByDevNo(Object imei) {
        return deviceWatchMapper.getDeviceByDevNo(imei);
    }
}
